<?php

declare(strict_types=1);
/*
 * This file is part of Leonsw.
 *
 * @link     https://leonsw.com
 * @document https://docs.leonsw.com
 * @contact  leonsw.com@gmail.com
 * @license  https://leonsw.com/LICENSE
 */

namespace App\Resource\Lottery3\Balance;


use Illuminate\Http\Resources\Json\JsonResource;

class Resource extends JsonResource
{
    public function toArray($request)
    {
        return [
            'id'             => $this->id ?? '',
            'name'           => $this->name ?? '',
            'image'          => $this->image ?? '',
            'special'        => $this->special ?? '',
            'coin'           => $this->coin ?? '',
            'name_image'     => $this->name_image ?? '',
            'min_score'      => $this->min_score ?? '',
            'max_score'      => $this->max_score ?? '',
            'show_max_score' => $this->show_max_score ?? '',
            'count'          => $this->user_balance->count ?? 0,
        ];
    }
}
